|
![](/i/fill.gif) |
Chris Huff <chr### [at] mac com> wrote:
> In article <3a3f589f@news.povray.org>, Geoff Wedig
> <wed### [at] darwin epbi cwru edu> wrote:
>> So, any of you Megapov gurus got any ideas? I this this is an
>> unsolveable limitation in the program, but maybe someone else has
>> found a way around it.
> Instead of defining a macro inside of another, change the value of a
> global variable and put all your macros in the file, with different
> names. Then, have the macro that you called(the one that was originally
> defined inside the other macro) decide what to do based on that
> variable. Probably the best way would be to use the #switch statement to
> call the desired macro.
That's probably what I'll have to do. It's not very extensible though. If
someone wants to use their own parameterization, that isn't provided in the
base code, they have to not only write the new macro, but give it an
identifier and add it to the multiplexer macro. Of course, I could write
some code that would add something to the multiplexer macro.... That could
even be an include rather than a macro itself, so could be done.
Hmm, can a macro be defined in terms of itself? Ie, can you have something
like:
#macro test_macro()
test_macro()
other stuff
#end
?
I'll test...
Anyway, I'm back in business. Thanks!
Geoff
Post a reply to this message
|
![](/i/fill.gif) |